/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.persistencia.domain;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Embeddable;
import javax.validation.constraints.NotNull;

/**
 *
 * @author SHERLY
 */
@Embeddable
public class SalonxmodalidaddictadoPK implements Serializable {
    @Basic(optional = false)
    @NotNull
    @Column(name = "nSlnId")
    private int nSlnId;
    @Basic(optional = false)
    @NotNull
    @Column(name = "nMdlDctId")
    private int nMdlDctId;

    public SalonxmodalidaddictadoPK() {
    }

    public SalonxmodalidaddictadoPK(int nSlnId, int nMdlDctId) {
        this.nSlnId = nSlnId;
        this.nMdlDctId = nMdlDctId;
    }

    public int getNSlnId() {
        return nSlnId;
    }

    public void setNSlnId(int nSlnId) {
        this.nSlnId = nSlnId;
    }

    public int getNMdlDctId() {
        return nMdlDctId;
    }

    public void setNMdlDctId(int nMdlDctId) {
        this.nMdlDctId = nMdlDctId;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (int) nSlnId;
        hash += (int) nMdlDctId;
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof SalonxmodalidaddictadoPK)) {
            return false;
        }
        SalonxmodalidaddictadoPK other = (SalonxmodalidaddictadoPK) object;
        if (this.nSlnId != other.nSlnId) {
            return false;
        }
        if (this.nMdlDctId != other.nMdlDctId) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "com.persistencia.domain.SalonxmodalidaddictadoPK[ nSlnId=" + nSlnId + ", nMdlDctId=" + nMdlDctId + " ]";
    }
    
}
